<!doctype html>
<html class="x-admin-sm">
<head>
    <meta charset="UTF-8">
    <title>餐饮后台管理系统登录</title>
    <meta name="renderer" content="webkit|ie-comp|ie-stand">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport"
          content="width=device-width,user-scalable=yes, minimum-scale=0.4, initial-scale=0.8,target-densitydpi=low-dpi"/>
    <meta http-equiv="Cache-Control" content="no-siteapp"/>
    <link rel="stylesheet" href="./css/font.css">
    <link rel="stylesheet" href="./css/login.css">
    <link rel="stylesheet" href="./css/xadmin.css">
    <script src="js/jquery.min.js"></script>
    <!--    <script src="js/vue.js"></script>-->
    <script src="https://cdn.staticfile.org/vue/2.4.2/vue.min.js"></script>
    <!--    <script src="https://cdn.jsdelivr.net/npm/vue@2.6.14"></script>-->
    <!--    <script src="https://cdn.jsdelivr.net/npm/vue@2.6.14/dist/vue.js"></script>-->
    <script src="./lib/layui/layui.js" charset="utf-8"></script>
    <script src="js/login.js"></script>


    <!--    很多时候我们的js不兼容  所以，针对不同浏览器可能会写不同的js代码-->
    <!--[if lt IE 9]>

    <script src="https://cdn.staticfile.org/html5shiv/r29/html5.min.js"></script>
    <script src="https://cdn.staticfile.org/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
</head>
<body class="login-bg">

<div class="login layui-anim layui-anim-up" id="form">
    <div class="message">x-admin2.0-管理登录</div>
    <div id="darkbannerwrap"></div>
    <!--form 叫做表单提交-->
    <!--    如果form表单有method，和action,则页面一般用jsp，
     如果用html，则删除method和action，我们通过ajax去提交数据-->
    <form class="layui-form">
        <input name="username" v-model="username" placeholder="用户名" type="text" lay-verify="username"
               class="layui-input">
        <!--        你输入的用户名为：<span id="tips">{{username}}</span>-->
        <hr class="hr15">
        <input name="password" lay-verify="password" placeholder="密码" type="password"
               class="layui-input">

        <hr class="hr15">
        <div style="display: flex ;align-items: center">
            <input name="code" lay-verify="code" placeholder="验证码" type="text">
            <img src="/code" id="code" width="80" height="30" onclick="changeCode()">
        </div>
        <hr class="hr15">
        <input value="登录" lay-submit lay-filter="login" style="width:100%;" type="submit">
        <hr class="hr20">
        <input type="hidden" value="" id="hid">
    </form>
</div>
<script>
    new Vue({
        el: '#form',//#代表id ，css的时候  选择器
        data: {
            username: 'supeng',
            password: 'aaaaaa'
        }
        //     data() {
        //         return {
        //             user:{
        //                 username:'',
        //                 password:''
        //             },
        //             rules: {
        //                 username: [
        //                     {
        //                         required: true,
        //                         message: '请输入用户名',
        //                         trigger: 'blur'
        //                     },
        //                     {
        //                         min: 6,
        //                         max: 16,
        //                         message: "请输入6到16位字符",
        //                         trigger: 'blur'
        //                     }
        //                 ],
        //                 password: [{pattern: '/^[0-9]{6}$/', message: '只能是6个数字'}]
        //             }
        //         }
        //     }
    })

</script>

</body>
</html>
